package messangerTypes;

@SuppressWarnings("serial")
public class ConnectRequest extends MessageBase implements java.io.Serializable
{
	private User requestedUser = null;
	private User requestingUser = null;
	private boolean login = false;
	
	public ConnectRequest (User requested, User requesting)
	{
		super(MessageBase.MessageType.CONNECT_REQUEST);
		this.requestedUser = requested;
		this.requestingUser = requesting;
	}

	public ConnectRequest (User requesting, Boolean login)
	{
		super(MessageBase.MessageType.CONNECT_REQUEST);
		this.requestingUser = requesting;
		this.login = login;
	}
	
	@Override
	public String toString()
	{
		return "ConnectRequest [requestedUser=" + requestedUser
				+ ", requestingUser=" + requestingUser + ", login=" + login
				+ "]";
	}

	public User getRequestedUser()
	{
		return requestedUser;
	}

	public User getRequestingUser()
	{
		return requestingUser;
	}

	public void setRequestedUser(User requestedUser)
	{
		this.requestedUser = requestedUser;
	}

	public void setRequestingUser(User requestingUser)
	{
		this.requestingUser = requestingUser;
	}

	public boolean isLogin()
	{
		return login;
	}
}
